]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
data: Update cldr2json script to new format
authorCarlos Garnacho <carlosg@gnome.org>
Wed, 13 Apr 2022 14:52:09 +0000 (16:52 +0200)
committerFlorian Müllner <fmuellner@gnome.org>
Wed, 10 Aug 2022 17:11:26 +0000 (17:11 +0000)
We want to extend the data model with additional keys, actions,
and properties. We need keys to be a map instead of a plain array
of strings.

Adapt the script to dump data in this new format, so it generates
a decent base to manually complete the work.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2278>

data/cldr2json/cldr2json.py

index c8258007f91bb24e249a2c4a33b6c80fcbb589ad..e5eb3cbe91243a8c2b9ef952a3ceaaa6f66d590a 100755 (executable)
@@ -79,7 +79,7 @@ def parse_rows(keymap):
                        reverse=True):
         row = []
         for key in sorted(v, key=lambda x: x):
-            row.append(key[1])
+            row.append({ 'strings': key[1] })
         rows.append(row)
 
     return rows